package firstMaven;

import org.springframework.context.support.ClassPathXmlApplicationContext;

public class BeanDefinitionDemo {

	public static void main(String[] args) {
		ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("bean.xml");
		HelloWordBean world = context.getBean(HelloWordBean.class);
		world.sayHello();
		HelloWorldChina china = context.getBean(HelloWorldChina.class);
		china.sayHello();
		china.sayHello2();
		context.close();

	}

}
